package com;

import io.airlift.airline.Option;

/**
 * @author 张述江
 * @date 2023-08-28
 */
public class ClientOptions {
    //     带默认值的optional option
    @Option(name = "--server", title = "随便输入一个", description = "测试时使用 (默认值： localhost:8080)")
    public String server = "localhost:8080";

    // 带默认值的optional option
//    @Option(name = "--user", title = "user", description = "Username")
//    public String user = System.getProperty("user.name");

    // optional option，默认值null（string的默认值）
//    @Option(name = "--password", title = "password", description = "Password")
//    public String password;

    // optional option，要么不使用该选项，要么使用时指定两个session属性
//    @Option(name = "--session", title = "session",
//            description = "Session property (property can be at most two; format: --session key1=value1 key2=value2; " +
//                    "use 'SHOW SESSION' to see available properties)",
//            arity = 2)
//    public final List<Property> sessionProperties = new ArrayList<>();

    // required option，使用command时必须使用debug选项；由于debug选项为boolean类型，也就是debug选项的值必须为true
//    @Option(name = "--debug", title = "debug", description = "Enable debug information", required = true)
//    public boolean debug;

    // --help显示帮助信息时，将隐藏该选项
//    @Option(name = "--advanced", title = "advanced-properties", hidden = true,
//            description = "Advanced  property (property can be used multiple times; format: --advanced key1=value1 --advanced key2=value2 ...)")
//    public List<Property> advancedProperties = new ArrayList<>();

}
